<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@page import="java.util.*,model.*,util.*,control.*"%>
    
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>留言处理</title>
</head>
<body>

<%
	request.setCharacterEncoding("utf-8");
	
	String lna = ParamUtil.getString(request,"lna");
	String lbt = ParamUtil.getString(request,"lbt");
	String ner = ParamUtil.getString(request,"ner");
	
	Liuyanban liuyanban= new Liuyanban();
	LiuyanbanControl lc = new LiuyanbanControl();
	
	liuyanban.setLiuyanName(lna);
	liuyanban.setLiuyanBiaoti(lbt);
	liuyanban.setLiuyanNeirong(ner);

	
	if(lc.insertLiuyanban(liuyanban))
	{
 %>
		<script language="javascript">
     alert("留言成功");
     window.location.href="liuyanban_list.jsp";
     </script>
		<%} else { %>
		<script language="javascript">
     alert("留言失败");
     window.location.href="liuyanban_list.jsp";
     </script>
		<%} %>
</body>
</html>
